Browser APIs that extend HTML: storage, geolocation, drag and drop, workers and more.
Alongside new elements, HTML5 introduced a family of JavaScript APIs that let pages do much more. Web Storage (localStorage and sessionStorage) keeps key-value data in the browser, the Geolocation API provides the user's position with permission, the Drag and Drop API makes elements draggable, and the Canvas API draws graphics. Web Workers run scripts on background threads, the History API enables navigation without full page loads, and the Fetch, Intersection Observer and Notification APIs are widely used in modern apps.
A popular interview question compares localStorage, sessionStorage and cookies: localStorage persists until cleared, sessionStorage lasts for the tab session, and cookies are sent with every HTTP request and have much smaller limits. Storage is synchronous and only holds strings, and it is accessible to any script on the page, so it shouldn't hold sensitive data like tokens that need protection from XSS. Knowing the trade-offs of each API matters more than listing them.
What you'll walk away knowing
No questions match "".